package file;

import java.io.File;
import java.io.IOException;

public class Test3 {

    public static void main(String[] args) throws IOException {

        File file = new File("D:/sweet.txt");
        System.out.println(file.exists());
        file.createNewFile();// 创建文件
        System.out.println(file.exists());

    }
}
